<div class="modal fade" data-backdrop="static" data-bind="modal:isShow" id="inline-source-modal">
    <div class="modal-dialog" data-bind="css:{'modal-lg':id}">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-bind="click:reset"><i class="fa fa-close"></i></button>
                <h4 class="modal-title" data-bind="text: Kooboo.text.common[_.capitalize(title())]"></h4>
            </div>
            <!-- ko if: id -->
            <div data-bind="error: text">
                <textarea id="inline-script" data-bind="value: text" class="hidden"></textarea>
            </div>
            <!-- /ko -->
            <!-- ko ifnot: id -->
            <div class="modal-body">
                <div class="form-horizontal">
                    <div class="form-group">
                        <label class="control-label col-md-2" data-bind="text: Kooboo.text.common[_.capitalize(title())]"></label>
                        <div class="col-md-10">
                            <select class="form-control" data-bind="value:text,error:text,optionText:'text'">
                                <optgroup data-bind="foreach:files, attr:{ label: Kooboo.text.component.styleScript.files}">
                                    <option data-bind="value:{url:url,name:text},text:text"></option>
                                </optgroup>
                                <optgroup data-bind="foreach:groups, attr:{ label: Kooboo.text.component.styleScript.groups}">
                                    <option data-bind="value:{url:url,name:text},text:text"></option>
                                </optgroup>
                            </select>
                        </div>
                    </div>
                </div>
            </div>
            <!-- /ko -->
            <div class="modal-footer">
                <button class="btn green" data-bind="click:save, enable:isResourceExist, text: Kooboo.text.common.save"></button>
                <button class="btn gray" data-bind="click:reset, text: Kooboo.text.common.cancel"></button>
            </div>
        </div>
    </div>
</div>